import serial
import time


while (True):
    ser = serial.Serial('/dev/ttyS3', 115200)
    ser.write("@1\r\n".encode())
    time.sleep(2)
    ser.write("@0\r\n".encode())
    time.sleep(2)



# # while True:
#     # ser.write("@0\r\n".encode())
#     # time.sleep(1)
# ser.write("@1\r\n".encode())
# time.sleep(5)
# ser.write("@2\r\n".encode())
#     # time.sleep(1)
#     # ser.write("@3\r\n".encode())
#     # time.sleep(1)

# time.sleep(5)

# ser.write("@0\r\n".encode())